package com.ruoyi.system.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 【请填写功能名称】对象 shop_cart
 * 
 * @author ruoyi
 * @date 2022-12-08
 */
public class ShopCart extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 购物车id */
    private Integer id;

    /** 商品id */
    @Excel(name = "商品id")
    private Integer productId;

    /** 商品图片 */
    @Excel(name = "商品图片")
    private String productImg;

    /** 用户id */
    @Excel(name = "用户id")
    private Integer userId;

    /** 购买数量 */
    @Excel(name = "购买数量")
    private Integer productNum;

    /** 总价 */
    @Excel(name = "总价")
    private Long productPrice;

    /** 商品规格 */
    @Excel(name = "商品规格")
    private String productProp;

    /** 购物车添加时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "购物车添加时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date cartTime;

    public void setId(Integer id) 
    {
        this.id = id;
    }

    public Integer getId() 
    {
        return id;
    }
    public void setProductId(Integer productId) 
    {
        this.productId = productId;
    }

    public Integer getProductId() 
    {
        return productId;
    }
    public void setProductImg(String productImg) 
    {
        this.productImg = productImg;
    }

    public String getProductImg() 
    {
        return productImg;
    }
    public void setUserId(Integer userId) 
    {
        this.userId = userId;
    }

    public Integer getUserId() 
    {
        return userId;
    }
    public void setProductNum(Integer productNum) 
    {
        this.productNum = productNum;
    }

    public Integer getProductNum() 
    {
        return productNum;
    }
    public void setProductPrice(Long productPrice) 
    {
        this.productPrice = productPrice;
    }

    public Long getProductPrice() 
    {
        return productPrice;
    }
    public void setProductProp(String productProp) 
    {
        this.productProp = productProp;
    }

    public String getProductProp() 
    {
        return productProp;
    }
    public void setCartTime(Date cartTime) 
    {
        this.cartTime = cartTime;
    }

    public Date getCartTime() 
    {
        return cartTime;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("productId", getProductId())
            .append("productImg", getProductImg())
            .append("userId", getUserId())
            .append("productNum", getProductNum())
            .append("productPrice", getProductPrice())
            .append("productProp", getProductProp())
            .append("cartTime", getCartTime())
            .toString();
    }
}
